package com.mdchina.thelifeorder.api

import io.reactivex.Observable
import okhttp3.ResponseBody
import retrofit2.http.*


/**
 * Created by LFC
on 2019/12/19.
 */
interface ApiService {
    @Streaming //大文件时要加不然会OOM
    @GET
    fun downloadFile(@Header("Range") range: String, @Url fileUrl: String): Observable<ResponseBody>

    @FormUrlEncoded
    @POST
    fun API_sms(@Url url: String, @FieldMap map: Map<String, String>): Observable<ResponseBody> //204.发送验证码

    @FormUrlEncoded
    @POST
    fun API_RegisterSms(@Url url: String, @FieldMap map: Map<String, String>): Observable<ResponseBody> //注册

    //    @FormUrlEncoded
//    @POST
//    fun API_Login(@Url url: String, @FieldMap map: Map<String, String>): Observable<LoginD> //登录
//
    @GET
    fun API_RZDevice(@Url url: String): Observable<ResponseBody> //获取任务详情
}